package elitech.vietnam.weatherfashion.dto;

import java.util.Date;
import com.google.gson.annotations.SerializedName;

import elitech.vietnam.weatherfashion.ultilities.Utilities;

public class CommentDTO {

	private int id;
	@SerializedName("id_mem")
	private int memberId;
	@SerializedName("id_post")
	private int postId;
	@SerializedName("cm_content")
	private String commentContent;
	@SerializedName("mem_id")
	private String memberUsername;
	@SerializedName("mem_name")
	private String memberName;
	@SerializedName("mem_pic")
	private String memberImage;
	@SerializedName("date")
	private String dateString;
	private Date dateComment;

	public String getCommentContent() {
		return commentContent;
	}

	public void setCommentContent(String commentContent) {
		this.commentContent = commentContent;
	}

	public Date getDateComment() {
		if (dateComment == null)
			dateComment = Utilities.parseDateFromStringFormat(dateString,
					"yyyy-MM-dd hh:mm:ss");
		return dateComment;
	}

	public void setDateComment(Date date) {
		this.dateComment = date;
	}

	public String getMemberName() {
		return memberName;
	}

	public void setMemberName(String memberName) {
		this.memberName = memberName;
	}

	public int getMemberId() {
		return memberId;
	}

	public void setMemberId(int memberId) {
		this.memberId = memberId;
	}

	public String getMemberImage() {
		return memberImage;
	}

	public void setMemberImage(String memberImage) {
		this.memberImage = memberImage;
	}

	public int getId() {
		return id;
	}

	public void setId(int id) {
		this.id = id;
	}

	public int getPostId() {
		return postId;
	}

	public void setPostId(int postId) {
		this.postId = postId;
	}

	public String getMemberUsername() {
		return memberUsername;
	}

	public void setMemberUsername(String memberUsername) {
		this.memberUsername = memberUsername;
	}

}
